#include <iostream>

using namespace std;

int main(int argc, char *args[])
{
	int n;
	while (scanf("%d", &n) && n != 0) {
		if (n % 2 == 0) {
			printf("No Solution!\n");
		} else {
			int half = n / 2 + 1;
			printf("%d\n", n - 1);
			/*if (half % 2 == 0) {
				printf("%d\n", n - 1);
			} else {
				printf("");
			}*/
		}
		/*for (int i = 0; i <= n / 2; i++) {
			int j = 0;
			while (j <= ) {

				++j;
			}
		}*/
	}
	return 0;
}